<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
    <link href="https://cdn.jsdelivr.net/npm/bootstrap@5.3.0-alpha3/dist/css/bootstrap.min.css" rel="stylesheet" 
    integrity="sha384-KK94CHFLLe+nY2dmCWGMq91rCGa5gtU4mk92HdvYe+M/SXH301p5ILy+dN9+nJOZ" crossorigin="anonymous">
    <script src="../作业/定义全班.js"></script>
</head>
<body>
    <h1 style="text-align: center;">计算机2221学生表</h1>
    <table id="students" class="table table-plain table-striped table-hover">
    </table>
    <script>
        tableObj=document.getElementById("students");
        var str='<tr><td>序号</td><td>学号</td><td>姓名</td></tr>';
        for(i in computer2221){
            str+="<tr>";
            str+="<td>"+i+"</td>";
            str+="<td>"+computer2221[i].no+"</td>";
            str+="<td>"+computer2221[i].name+"</td>";
            str+="</tr>";
        }
        tableObj.innerHTML=str;
    </script>
</body>
</html>